import 'package:shared_preferences/shared_preferences.dart';

class LLShareData {
  static Future<bool> setString(String key, String value) async {
    SharedPreferences prefs = await SharedPreferences.getInstance();
    bool ret = await prefs.setString(key, value);
    return ret;
  }

  static Future<String?> getString(String key) async {
    SharedPreferences prefs = await SharedPreferences.getInstance();
    String? ret = prefs.getString(key);
    return ret;
  }

  static Future<bool> setBool(String key, bool value) async {
    SharedPreferences prefs = await SharedPreferences.getInstance();
    bool ret = await prefs.setBool(key, value);
    return ret;
  }

  static Future<bool?> getBool(String key) async {
    SharedPreferences prefs = await SharedPreferences.getInstance();
    bool? ret = prefs.getBool(key);
    return ret;
  }
}
